﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace AbstractFactory
{
    class Program
    {
        static void Main(string[] args)
        {
            AbstractFactory factory = null;
            string flag="mac";
            switch (flag)
            {
                case "win":
                    factory = new WinFactory();
                    break;
                case "mac":
                    factory = new MacFactorty();
                    break;
            }

            Button button = factory.CreateButton();
            button.WhoAmI();
            Console.Read();
        }
    }
}
